#ifndef EVENT_H
#define EVENT_H
#include <glib.h>
#include <stdio.h>

#define EVENT_STR_BUFSZ 4096

typedef struct Event {
    gchar host[EVENT_STR_BUFSZ];
    gchar type[EVENT_STR_BUFSZ];
    gchar source_type[EVENT_STR_BUFSZ];
    gchar source[EVENT_STR_BUFSZ];
    gchar target_type[EVENT_STR_BUFSZ];
    gchar target[EVENT_STR_BUFSZ];
    gboolean remove_target; // remove target? terminate/delete/close port
} Event;

Event *event_create ();

int event_populate (Event *e,  gchar *host,  gchar *type,  gchar *source,  gchar *source_type, 
                                         gchar *target,  gchar *target_type);

int event_copy (Event *from, Event *to);

int event_clear (Event *e);

int event_destructor (Event *e);

int event_output (Event *e, FILE* out);

#endif